<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
      <!-- v-if="条件" -->
      <div class="info" v-if="Object.keys(info).length">
        <h2>个人信息</h2>
        <ul>
          <li>姓名：{{info.name}}</li>
          <li>姓名：{{info.age}}</li>
        </ul>
      </div>

      <!-- v-else -->
      <div v-else>
        <h2>没有输入个人信息</h2>
        <p>请输入个人信息后，再进行展示</p>
      </div>
    </div>

    <script src="./lib/Vue.js"></script>
    <script>
        const app = Vue.createApp({
            data() {
                return{
                  info:{}
                }
            }
        })
        app.mount("#app")
    </script>
</body>
</html>